package code.c01;

import java.util.Scanner;

/**
 * @author thinkpad - 83start
 * @version v1.0
 * @create 2022/9/1 12:19
 * @package PACKAGE_NAME
 * @description 文件说明
 */

public class IsPrime {
    public static void main(String[] args) {
        int i = new Scanner(System.in).nextInt();
        System.out.println(isPrime(i));
    }

    public static boolean isPrime(int num){
        int numSqrt = (int) Math.sqrt(num);
        for (int i = 2; i <=numSqrt ; i++) {
            if (num % i == 0){
                return false;
            }
        }

        return true;
    }
}
